package com.gxa.stu.util;

import java.util.Random;

/**
 * @author: zyz
 * @Project: JavaLaity
 * @Pcakage: com.gxa.stu.util.RandomUtil
 * @Date: 2022年11月02日 11:46
 * @Description: 生成随机数
 */
public class RandomUtil {
    public static String random(Integer size){
        StringBuilder stringBuilder = new StringBuilder();
        Random random = new Random();
        for(int i=0;i<size;i++){
            stringBuilder.append(random.nextInt(9)+1);
        }
        return stringBuilder.toString();
    }
}